<?php
require_once 'databaseconnection.php';
$username=$_POST['username'];
$password=$_POST['password'];
$passwordmd5=md5($password);
$queryres=mysql_query("SELECT * FROM user WHERE Login_Username='$username' AND Password='$passwordmd5'");
while($row=mysql_fetch_array($queryres))
  {
  
	$_SESSION['First_Name']=$row['First_Name'];
	$_SESSION['Last_Name']=$row['Last_Name'];
	
	}
if(authanti($username,md5($password)))
{
	session_start();
	$_SESSION['username']=$username;
	$_SESSION['password']=$password;
	
	require_once 'index1.php';
	}
else
{
$error1="Incorrect username or password!";
	$_SESSION['error1']=$error1;
	require_once 'index.php';
}
?>
